package com.amazon.ags.jni.profiles;

import android.util.Log;
import com.amazon.ags.api.AGResponseHandle;
import com.amazon.ags.api.AmazonGamesClient;
import com.amazon.ags.api.profiles.ProfilesClient;
import com.amazon.ags.api.profiles.RequestPlayerProfileResponse;

public class ProfilesNativeHandler
{
  private static final String TAG = ProfilesNativeHandler.class.getSimpleName();
  private static ProfilesClient m_ProfilesClient = null;

  public static void getLocalPlayerProfile(int paramInt, long paramLong)
  {
    if (m_ProfilesClient == null)
    {
      Log.e(TAG, "requestLocalPlayerProfile - initializeJni was not called beforehand.");
      return;
    }
    m_ProfilesClient.getLocalPlayerProfile(new Object[0]).setCallback(new RequestLocalPlayerProfileJniResponseHandler(paramInt, paramLong));
  }

  public static AGResponseHandle<RequestPlayerProfileResponse> getLocalPlayerProfileHandle(int paramInt)
  {
    if (m_ProfilesClient == null)
    {
      Log.e(TAG, "requestLocalPlayerProfileHandle - initializeJni was not called beforehand.");
      return null;
    }
    ProfilesClient localProfilesClient = m_ProfilesClient;
    Object[] arrayOfObject = new Object[1];
    arrayOfObject[0] = Integer.valueOf(paramInt);
    return localProfilesClient.getLocalPlayerProfile(arrayOfObject);
  }

  public static void initializeNativeHandler(AmazonGamesClient paramAmazonGamesClient)
  {
    m_ProfilesClient = paramAmazonGamesClient.getProfilesClient();
  }
}

/* Location:           E:\android\Toy Defense 2_dex2jar.jar
 * Qualified Name:     com.amazon.ags.jni.profiles.ProfilesNativeHandler
 * JD-Core Version:    0.6.2
 */